3.56 \(\int \frac{(a+b x)^2}{x} \, dx\)

Optimal. Leaf size=22 \[ a^2 \log (x)+2 a b x+\frac{b^2 x^2}{2} \]

[Out]

2*a*b*x + (b^2*x^2)/2 + a^2*Log[x]

_______________________________________________________________________________________

Rubi [A]  time = 0.0173239, antiderivative size = 22, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 11, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.091 \[ a^2 \log (x)+2 a b x+\frac{b^2 x^2}{2} \]

Antiderivative was successfully verified.

[In]  Int[(a + b*x)^2/x,x]

[Out]

2*a*b*x + (b^2*x^2)/2 + a^2*Log[x]

_______________________________________________________________________________________

Rubi in Sympy [F]  time = 0., size = 0, normalized size = 0. \[ a^{2} \log{\left (x \right )} + 2 a b x + b^{2} \int x\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate((b*x+a)**2/x,x)

[Out]

a**2*log(x) + 2*a*b*x + b**2*Integral(x, x)

_______________________________________________________________________________________

Mathematica [A]  time = 0.00109338, size = 22, normalized size = 1. \[ a^2 \log (x)+2 a b x+\frac{b^2 x^2}{2} \]

Antiderivative was successfully verified.

[In]  Integrate[(a + b*x)^2/x,x]

[Out]

2*a*b*x + (b^2*x^2)/2 + a^2*Log[x]

_______________________________________________________________________________________

Maple [A]  time = 0.004, size = 21, normalized size = 1. \[ 2\,abx+{\frac{{b}^{2}{x}^{2}}{2}}+{a}^{2}\ln \left ( x \right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int((b*x+a)^2/x,x)

[Out]

2*a*b*x+1/2*b^2*x^2+a^2*ln(x)

_______________________________________________________________________________________

Maxima [A]  time = 1.33571, size = 27, normalized size = 1.23 \[ \frac{1}{2} \, b^{2} x^{2} + 2 \, a b x + a^{2} \log \left (x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x + a)^2/x,x, algorithm="maxima")

[Out]

1/2*b^2*x^2 + 2*a*b*x + a^2*log(x)

_______________________________________________________________________________________

Fricas [A]  time = 0.200845, size = 27, normalized size = 1.23 \[ \frac{1}{2} \, b^{2} x^{2} + 2 \, a b x + a^{2} \log \left (x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x + a)^2/x,x, algorithm="fricas")

[Out]

1/2*b^2*x^2 + 2*a*b*x + a^2*log(x)

_______________________________________________________________________________________

Sympy [A]  time = 1.00371, size = 20, normalized size = 0.91 \[ a^{2} \log{\left (x \right )} + 2 a b x + \frac{b^{2} x^{2}}{2} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x+a)**2/x,x)

[Out]

a**2*log(x) + 2*a*b*x + b**2*x**2/2

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.210121, size = 28, normalized size = 1.27 \[ \frac{1}{2} \, b^{2} x^{2} + 2 \, a b x + a^{2}{\rm ln}\left ({\left | x \right |}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x + a)^2/x,x, algorithm="giac")

[Out]

1/2*b^2*x^2 + 2*a*b*x + a^2*ln(abs(x))